import useRequest from '../hook/request';

// 分院列表
export function getSubCompanyListApi(params: any) {
  return useRequest(
    'company/subCompany/getSubCompanyList',
    params,
    'GET'
  )
}

// 添加分院
export function addSubCompanyApi(params: any) {
  return useRequest(
    'company/subCompany/addSubCompany',
    params,
    'POST'
  )
}

// 修改分院
export function updateSubCompanyApi(params: any) {
  return useRequest(
    'company/subCompany/updateSubCompany',
    params,
    'POST'
  )
}

// 删除分院
export function delSubCompanyApi(params: any, id:number) {
  return useRequest(
    `company/subCompany/delSubCompany/${id}`,
    params,
    'POST'
  )
}